#!/usr/bin/python
# -*- coding:utf-8 -*-
# @author  : micah
# @time    : 2023/10/30 22:26
# @function: the script is used to do something.
# @version :

from flask import Flask, jsonify
# flask_cors
from flask_cors import CORS

app = Flask(__name__)  # 实例化 __name__:测试服务器
CORS(app)


@app.route('/data')
def get_data():
    user_info = {'name': '安娜', 'age': 18, 'address': '长沙'}
    return jsonify(user_info)


if __name__ == '__main__':
    app.run(host='127.0.0.1', port=5000, debug=True)
